Added interactive quantum circuit playground with tutorials#9
Added interactive quantum circuit playground with tutorials#9CodeMaverick2 wants to merge 3 commits intoOpenQuantumDesign:mainfrom
Conversation
|
@benjimaclellan Would love your feedback on this and if any changes are required do let me know |
|
Why are yu copying from others PR, kindly give some chance to other participants thank you Maintainer please take note while reviewing |
|
I’m not sure what you mean. If you’re suggesting that I copied your PR, I’d encourage you to carefully review both submissions they are quite different, and mine directly addresses the requirements outlined in the issue. I had discussed my implementation plan with the maintainer before starting work when no one had commented on the issue. I’ve also closed another issue in this repository, so I’m familiar with the expected standards. Additionally, I’d recommend reviewing your own PR again it may help clarify how the issue requirements are intended to be solved. If you have specific technical concerns, I’m happy to discuss them constructively. Let’s keep the conversation focused on the code and the actual requirements. Making accusations without clear evidence isn’t productive, and difficulty in solving an issue isn’t a valid reason to blame others |
maintainers kindly note while reviewing thank yu i will leave this to the maintainers |
|
@learningdungeon @AbdullahKazi500 @ dhanaa abhirjk hey guys I would also suggesst checking yur work and pr if you made any contributions for the issue thnks again . |
|
Hi @CodeMaverick2 - thanks for another PR! It looks great, and complements the previous bounty. I'm reviewing all the PRs currently before the end of the hackathon. My only comment from the video you posted (thanks for providing it!) is that the two-qubit gates, e.g., CNOT are not visualized what the second qubit register it acts on is. I see no overlap in the code that was submitted between PRs for this bounty, and have provided feedback on each about how they solve the posted issue. In addition, all participants are allowed to submit multiple PRs. |
please check main.py at https://github.com/learningdungeon/GATE |
|
@benjimaclellan Thanks for the feedback! Updated the CNOT visualization both the control and target qubits are now shown on the circuit grid. Control qubit displays ●→{target} and target qubit displays ⊕←{control}, at the same time step. Clearing either end removes both. Regarding the copying claims I had shared my implementation approach with you before anyone else commented on the issue, and this PR complements my earlier analog builder (#5). I appreciate you confirming there's no overlap. Happy to leave it at that and let the work speak for itself. Demo - Screen.Recording.2026-02-27.023909.mp4 |
|
@benjimaclellan Also fixed gate colors on the circuit grid each gate type now renders in its distinct color: - X = red
|
benjimaclellan
left a comment
There was a problem hiding this comment.
Thanks @CodeMaverick2, thanks for making those changes. The PR tackles the bounty nicely and looks like a useful addition to the demo - I'll accept it now and assign the bounty to this submission.

Summary
Interactive digital quantum circuit builder that lets users visually build circuits, simulate quantum states, and execute on hardware. Complements the analog program builder (#5) to complete the teaching demo for Issue #3.
What's New
3 new modules:
digital_simulator.py- quantum state simulation (kronecker product math, measurement sampling)digital_compiler.py- compiles Circuit → laser intensity patterns + trap commandsgui/circuit_builder.py- interactive NiceGUI UI with circuit grid, gate palette, and results panelModified:
digital.py- fixed pydantic v2 compatibility (root_validator→model_validator), relaxed qubit count to match 4-laser hardwaregui/programs.py- added preset circuits (Bell state, GHZ, superposition, X gate)gui/main.py- wired "Quantum Playground" button to circuit builderFeatures:
Demo -
Screen.Recording.2026-02-24.110521.1.mp4
Test Plan
python src/oqd_teaching_demo/gui/main.pystarts without errors (MOCK=True)Closes - #3